package mock

import (
	"net/http"

	"mall/common/resultx"
	"mall/service/forum/api/internal/logic/mock"
	"mall/service/forum/api/internal/svc"
)

func ViewHomePageHandler(svcCtx *svc.ServiceContext) http.HandlerFunc {
	return func(w http.ResponseWriter, r *http.Request) {
		l := mock.NewViewHomePageLogic(r.Context(), svcCtx)
		resp, err := l.ViewHomePage()
		resultx.HttpResult(r, w, resp, err)
	}
}
